import { takeEvery ,put } from 'redux-saga/effects'  
import {GET_MY_LIST} from './actionTypes'
import {getListAction} from './actionCreatores'
import axios from 'axios'


function* mySaga() {
  yield takeEvery(GET_MY_LIST, getList)
} 
function* getList(){
  const res = yield axios.get('http://www.ssyong.club:3000/reactTestData')
  const action = getListAction(res.data)
  yield put(action)
}
export default mySaga;